package com.entity;

import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.annotations.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.beanutils.BeanUtils;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.lang.reflect.InvocationTargetException;
import java.util.Date;

/**
 * 客房类型
 * 数据库通用操作实体类（普通增删改查）
 */
@TableName("kefangleixing")
public class KefangleixingEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	public KefangleixingEntity() {
	}

	public KefangleixingEntity(Object t) {
		try {
			BeanUtils.copyProperties(this, t);
		} catch (IllegalAccessException | InvocationTargetException e) {
			e.printStackTrace();
		}
	}

	/**
	 * 主键id
	 */
	@TableId
	private Long id;

	/**
	 * 客房类型名称
	 */
	private String kefangleixing;

	/**
	 * 最大入住人数
	 */
	@TableField("max_people")
	private Integer maxPeople;

	/**
	 * 床型
	 */
	@TableField("bed_type")
	private String bedType;

	/**
	 * 房间面积
	 */
	@TableField("room_area")
	private Double roomArea;

	/**
	 * 是否含早餐
	 */
	@TableField("breakfast_included")
	private Boolean breakfastIncluded;

	/**
	 * 是否可吸烟
	 */
	@TableField("smoking_allowed")
	private Boolean smokingAllowed;

	/**
	 * 是否提供无线网络
	 */
	@TableField("wifi_available")
	private Boolean wifiAvailable;

	/**
	 * 价格范围
	 */
	@TableField("price_range")
	private String priceRange;

	/**
	 * 季节性折扣
	 */
	@TableField("seasonal_discount")
	private String seasonalDiscount;

	/**
	 * 促销活动
	 */
	@TableField("promotion")
	private String promotion;

	/**
	 * 添加时间
	 */
	@JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat
	private Date addtime;

	// Getter 和 Setter 方法
	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getKefangleixing() {
		return kefangleixing;
	}

	public void setKefangleixing(String kefangleixing) {
		this.kefangleixing = kefangleixing;
	}

	public Integer getMaxPeople() {
		return maxPeople;
	}

	public void setMaxPeople(Integer maxPeople) {
		this.maxPeople = maxPeople;
	}

	public String getBedType() {
		return bedType;
	}

	public void setBedType(String bedType) {
		this.bedType = bedType;
	}

	public Double getRoomArea() {
		return roomArea;
	}

	public void setRoomArea(Double roomArea) {
		this.roomArea = roomArea;
	}

	public Boolean getBreakfastIncluded() {
		return breakfastIncluded;
	}

	public void setBreakfastIncluded(Boolean breakfastIncluded) {
		this.breakfastIncluded = breakfastIncluded;
	}

	public Boolean getSmokingAllowed() {
		return smokingAllowed;
	}

	public void setSmokingAllowed(Boolean smokingAllowed) {
		this.smokingAllowed = smokingAllowed;
	}

	public Boolean getWifiAvailable() {
		return wifiAvailable;
	}

	public void setWifiAvailable(Boolean wifiAvailable) {
		this.wifiAvailable = wifiAvailable;
	}

	public String getPriceRange() {
		return priceRange;
	}

	public void setPriceRange(String priceRange) {
		this.priceRange = priceRange;
	}

	public String getSeasonalDiscount() {
		return seasonalDiscount;
	}

	public void setSeasonalDiscount(String seasonalDiscount) {
		this.seasonalDiscount = seasonalDiscount;
	}

	public String getPromotion() {
		return promotion;
	}

	public void setPromotion(String promotion) {
		this.promotion = promotion;
	}

	public Date getAddtime() {
		return addtime;
	}

	public void setAddtime(Date addtime) {
		this.addtime = addtime;
	}
}